import fetch from '@/utils/fetch';

function request({method,url,data,params}){
    return fetch(method,url, data,params)
}
// 查询
export const searchApi = (params) => {
    return request({
        method: 'post',
        url: '/dms/moldWarehousing/getDeviceTzList',
        data: params
    })
}

// 增加
export const addApi = (params) => {
    return request({
        method: 'post',
        url: '/dms/moldWarehousing/addMoldWarehousing',
        data: params
    })
}
// 获取详情
export const getMoldInfoList= (params) => {
    return request({
        method: 'post',
        url: '/dms/moldWarehousing/getMoldInfoList',
        data:{
            pageSize:25,
            pageNum:1,
            ...params
        },
    })
}
export const deleteApi= (params) => {
    return request({
        method: 'DELETE',
        url: '/dms/moldWarehousing/deleteById',
        params: params
    })
}
// 入库申请审批
export const approval= (params) => {
    return request({
        method: 'POST',
        url: '/dms/moldWarehousing/approval',
        data: params
    })
}
// 修改模具入库申请
export const updateMoldWarehousing= (params) => {
    return request({
        method: 'POST',
        url: '/dms/moldWarehousing/updateMoldWarehousing',
        data: params
    })
}